<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>循环</title>
</head>

<body>

</body>

</html>
<script>
    //for循环
    for (var i = 0; i <= 100; i++) {
        if(i % 3 == 0 && i % 5 == 0) {
            console.log(i);

        }
    }

    var a = prompt('输入A')
    var B = prompt('输入B')
var str=''
var sum = 0 
for(var i=0; i<b; i++){
    str +=a
    sum += Number(str)
    console.log(sum);
}console.log(sum);



</script>